﻿package mortal.game.net.command.copy.groupCopy
{
    import Framework.MQ.*;
    import Message.DB.Tables.*;
    import Message.Public.*;
    import com.mui.controls.*;
    import extend.language.*;
    import mortal.game.cache.*;
    import mortal.game.events.*;
    import mortal.game.mvc.*;
    import mortal.game.net.broadCast.*;
    import mortal.game.resource.*;
    import mortal.game.view.copy.groupCopy.data.*;
    import mortal.mvc.core.*;

    public class GroupCopyInviteProcessCommand extends BroadCastCall
    {

        public function GroupCopyInviteProcessCommand(param1:Object)
        {
            super(param1);
            return;
        }// end function

        override public function call(param1:MessageBlock) : void
        {
            var tcopy:TCopy;
            var closeAlert:Function;
            var mb:* = param1;
            closeAlert = function (param1:int) : void
            {
                var _loc_2:GroupCopyLeaveOperData = null;
                if (param1 == Alert.OK)
                {
                    Dispatcher.dispatchEvent(new DataEvent(EventName.CopyGroupEnter, tcopy.code));
                }
                else if (param1 == Alert.CANCEL)
                {
                    _loc_2 = new GroupCopyLeaveOperData();
                    _loc_2.isShowAler = false;
                    Dispatcher.dispatchEvent(new DataEvent(EventName.GroupLeave, _loc_2));
                }
                return;
            }// end function
            ;
            var value:* = mb.messageBase as SPublicInt;
            tcopy = CopyConfig.instance.getCopyInfoByCode(Cache.instance.group.sgroup.copyCode);
            Alert.show(Language.getStringByParam(30816, tcopy.name, value.publicInt + "/" + tcopy.totalBossNum), null, Alert.OK | Alert.CANCEL, null, closeAlert, null, 4);
            return;
        }// end function

    }
}
